package org.meb.speedway.web;

import java.util.Collections;
import java.util.HashMap;
import java.util.Map;

import javax.enterprise.context.ApplicationScoped;
import javax.inject.Named;

import lombok.Getter;

import org.meb.speedway.util.Patterns;

@Named
@ApplicationScoped
public class PatternsBean {

	@Getter
	private Map<String, String> patterns;

	public PatternsBean() {
		Map<String, String> map = new HashMap<String, String>();
		map.put("DATE_SHORT", Patterns.DATE_SHORT);
		map.put("DATE_SHORT_R", Patterns.DATE_SHORT_R);
		map.put("DATE_LONG", Patterns.DATE_LONG);
		map.put("DATE_LONG_R", Patterns.DATE_LONG_R);
		map.put("TIMESTAMP", Patterns.TIMESTAMP);
		map.put("TIMESTAMP_R", Patterns.TIMESTAMP_R);
		map.put("HOUR_MIN", Patterns.HOUR_MIN);
		map.put("HOUR_MIN_SEC", Patterns.HOUR_MIN_SEC);
		patterns = Collections.unmodifiableMap(map);
	}
}
